using GameFramework.Localization;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityGameFramework.Runtime;

namespace LS.Localization
{
    public class LanguageSetting : ScriptableObject
    {
        [SerializeField]
        private Language m_Language = Language.Unspecified;

        [SerializeField]
        private List<TextAsset> m_Datas = new List<TextAsset>();

        public List<TextAsset> Datas
        {
            get
            {
                return m_Datas;
            }
        }

        public Language Language
        {
            get
            {
                return m_Language;
            }

            set
            {
#if UNITY_EDITOR
                if(!Application.isPlaying)
                    m_Language = value;
                else
                    Log.Warning("LanguageSetting.Language Can not set value in Runtime!");
#else
                    Log.Warning("LanguageSetting.Language Can not set value in Runtime!");
#endif
            }
        }
    }
}
